home *** CD-ROM | disk | FTP | other *** search
/ Internet Info 1994 March / Internet Info CD-ROM (Walnut Creek) (March 1994).iso / inet / internet-drafts / draft-ietf-uri-url-01.txt < prev    next >
Text File  |  1993-07-20  |  48KB  |  1,024 lines

  1.  
  2.  
  3.  
  4. Uniform Resource Locators              Tim Berners-Lee
  5. INTERNET DRAFT                                    CERN
  6. IETF URL Working Group                    14 July 1993
  7.  
  8.  
  9.  
  10.                           Uniform Resource Locators
  11.  
  12.  
  13.      Status of this memo
  14.  
  15.             This document is an Internet Draft.  Internet Drafts are
  16.           working documents of the Internet Engineering Task Force
  17.           (IETF), its Areas, and its Working Groups.  Note that other
  18.           groups may also distribute working documents as Internet
  19.           Drafts.
  20.             Internet Drafts are working documents valid for a maximum of
  21.           six months.  Internet Drafts may be updated, replaced, or
  22.           obsoleted by other documents at any time.  It is not
  23.           appropriate to use Internet Drafts as reference material or to
  24.           cite them other than as a "working draft" or "work in
  25.           progress".
  26.             Distribution of this document is unlimited.  Please send
  27.           comments to the author as timbl@info.cern.ch. or to the
  28.           discussion list  ietf-url@merit.edu.
  29.  
  30.      Abstract
  31.  
  32.             Many protocols and systems for document search and retrieval
  33.           are currently in use, and many more protocols or refinements
  34.           of existing protocols are to be expected in a field whose
  35.           expansion is explosive.
  36.             These systems are aiming to achieve global search and
  37.           readership of documents across differing computing platforms,
  38.           and despite a plethora of protocols and data formats.   As
  39.           protocols evolve, gateways can allow global access to remain
  40.           possible. As data formats evolve, format conversion programs
  41.           can preserve global access.  There is one area, however, in
  42.           which it is impractical to make conversions, and that is in
  43.           the names and addresses used to identify objects.  This is
  44.           because names and addresses of objects are passed on in so
  45.           many ways, from the backs of envelopes to hypertext objects,
  46.           and may have a long life.
  47.             This paper discusses the requirements on a universal syntax
  48.           which can be used to refer to objects available using existing
  49.           protocols, and may be extended with technology.  It makes a
  50.           recommendation for a generic syntax, and for specific forms
  51.           for "Uniform Resource Locators" (URLs)of objects accessible
  52.           using existing Internet protocols.
  53.  
  54. Uniform Resource Locators                        Berners-Lee
  55.  
  56.  
  57.  
  58.      Terms
  59.  
  60.             The objects on the network which are to be named and
  61.           addressed include typically objects which can be retrieved,
  62.           and objects which can be searched.   There is a great variety
  63.           of other objects which may support other operations.  We imply
  64.           nothing about the contents of objects in this document.
  65.           Whereas human-readable documents are currently the center of
  66.           interest of the field, we envisage all aspects discussed in
  67.           this paper applying to generalised objects when systems to
  68.           handle them become available. The "object" is the unit of
  69.           reference and need not correspond to any unit of storage.  We
  70.           refer to objects which can be searched as "indexes".  We
  71.           emphasise that this is the abstract view of the client, and
  72.           these objects need not correspond to physical files on
  73.           computers. We refer to the person who does the retrieval or
  74.           searching as the user.
  75.             Within this document, we use the terms "name" very generally
  76.           for a string of characters describing an object,  whatever its
  77.           combination of properties mentioned below.  (The term usually
  78.           has a narrower meaning but we needed some term for the
  79.           universal set).  The term "address" is reserved for an string
  80.           which specifies a more or less physical location.  The term
  81.           "locator" refers to a URL as here defined.
  82.  
  83.      Requirements
  84.  
  85.             This section discusses requirements for URLs, as an
  86.           introduction of and background for the Recommendations
  87.           section.
  88.  
  89.         Uses of names and addresses
  90.  
  91.             A name allows a user, with the help of a "client" program,
  92.           to retrieve or operate on objects via a "server" program.  A
  93.           name may be passed for example:
  94.                   - In communication of any form between two people, to
  95.                     refer to a document, or part of a document;
  96.                   - As part of the description of a link associated with
  97.                     a hypertext document;
  98.                   - As part of the result of searching an index.
  99.             Some typical requirements on a name which are met to a
  100.           varying degree by various schemes are for example that the
  101.           name is
  102.             Persistent     A given name will remain valid as long as it
  103.                            is needed;
  104.             Extensible     A given naming syntax will remain valid
  105.                            through the introduction of new protocols and
  106.                            directory technologies;
  107.             Resolvable     A name will contain enough information to
  108.                            allow the document or index to which it
  109.  
  110.  
  111. Internet Draft               2              March 1993 Uniform Resource Locators                        Berners-Lee
  112.  
  113.  
  114.                            refers to be accessed, perhaps via resolution
  115.                            into an intermediate, more physical, name.
  116.             Unique         Each object can only have one such name.  The
  117.                            fact that two such names are different
  118.                            implies that the objects to which they refer
  119.                            are different (in some way).
  120.             Unambiguous    The fact that two names are identical implies
  121.                            that the objects named are the same (in some
  122.                            way).
  123.             The syntax discussed is the syntax of one name, be it a
  124.           lasting name or a physical address.  When a directory server
  125.           or hypertext link contains a set of alternative names, then
  126.           that is beyond the scope of this syntax.  Similarly, a syntax
  127.           for describing a compound object is outside the scope of this
  128.           syntax.  The specific locator name spaces (defined under the
  129.           umbrella of the general syntax) each meet the requirements
  130.           above to a greater or lesser extent.
  131.  
  132.         Current practice
  133.  
  134.             Current protocols use many different standards for names.
  135.           For some protocols, such as ISO-10163 Search and Retrieve
  136.           protocol[16], the names returned in a search are only valid
  137.           during the session. For others, such as FTP[9], they are
  138.           lasting names which may be used for object retrieval at a
  139.           later time.  Typically, however, they are not long-lasting
  140.           names which are independent of the location of the object.
  141.           Such names may be provided using directory servers such as
  142.           x.500.  They will refer to the registration, however formal or
  143.           informal, of a object with a particular organisation or
  144.           person.  Both hypertext and  manual references rely on long-
  145.           lasting names.
  146.             Current names are basically location specifiers (addresses).
  147.           These may be known as Uniform Resource Locators (URLs). They
  148.           give the necessary parts of an address for a reader to access
  149.           an information provider using the given protocol, and ask for
  150.           the object required. Examples of names used by various
  151.           protocols include
  152.  
  153. File Transfer Protocol (Postel 1985):
  154.                          Host name or IP-address
  155.                               [TCP port]
  156.                          [user name, password]
  157.                          Filename
  158.  
  159. W.A.I.S. (Kahle 1990)         Host name or IP-address
  160.                          [TCP port]
  161.                          database name
  162.                          local document id
  163.  
  164. Gopher (Alberti 1991)         Host name or IP-address
  165.                          [TCP port]
  166.  
  167.  
  168. Internet Draft               3              March 1993 Uniform Resource Locators                        Berners-Lee
  169.  
  170.  
  171.                          database name
  172.                          selector string
  173.  
  174. HTTP (Berners-Lee 1991)       Host name or IP-address
  175.                          [TCP port]
  176.                          local object id
  177.  
  178. NNTP (Kantor 1986) group Group name
  179.  
  180. NNTP article             Host name
  181.                          unique message identifier
  182.  
  183. Prospero links (Neuman 1992)  Host name or IP address
  184.                          [UDP port]
  185.                          Host specific object name
  186.                          [version]
  187.                          [identifier]*
  188.  
  189. x.500 distinguished name Country
  190.                          Organisation
  191.                          Organisational unit
  192.                          Person
  193.                          Local object identifier
  194.  
  195.  
  196.             Other systems with their own naming schemes include BITNET
  197.           "LISTSERV" application, FTAM file retrieval, SQLnetTM remote
  198.           database search, proprietary  distributed file systems, etc.
  199.           Conventional syntax for writing these addresses involve
  200.           various forms of punctuation to separate these parts.  This
  201.           sometimes,  but not always, allows the naming scheme to be
  202.           deduced from the punctuation.  For example, a name of the form
  203.           xxx.yyy.zz.edu:/pub.aa.bb.cc  often implies anonymous FTP
  204.           access.  However, there is no well-defined algorithm for
  205.           parsing an arbitrary name, as there is no common syntax.
  206.  
  207.  
  208.         Expandability
  209.  
  210.  
  211.             There will necessarily be a phase during which lasting names
  212.           will become more  common, as the deployment of directory
  213.           services increases to the point where  every user has direct
  214.           or indirect access to one.  Even then, however, one can
  215.           envisage more than one competing directory system, and cases
  216.           in which physical  names are still required.  A directory
  217.           service takes a lasting name and reduces it  to a physical
  218.           address (or set of addresses) which, though less useful for
  219.           lasting reference, is the only way to actually retrieve the
  220.           object.
  221.  
  222.  
  223.  
  224.  
  225. Internet Draft               4              March 1993 Uniform Resource Locators                        Berners-Lee
  226.  
  227.  
  228.             An addressing syntax is required which will be able to
  229.           encompass existing  physical address spaces, and be extendible
  230.           to any future protocols.  This  requires that it contain an
  231.           identifier for the protocol in use. The format of the rest  of
  232.           the address will necessarily depend to a certain extent on the
  233.           protocol.
  234.  
  235.  
  236.         Relevance
  237.  
  238.             The life of a name is limited by any information contained
  239.           within it which may  become prematurely invalid. It is
  240.           therefore necessary to limit the contents of a name to the
  241.           information required for the operations above.  Other
  242.           extraneous information about the object (its size, data
  243.           format, authorisation details, etc.) may in general change
  244.           with time and should not be part of the name.
  245.             One might expect such information to be part of the "header"
  246.           of a object, and for protocols to allow the header information
  247.           to be retrieved independently of the objects themselves.
  248.             Any physical address may be subject to change with time:
  249.           hence we encourage the move to lasting names and directory
  250.           services.
  251.  
  252.         Uniqueness
  253.  
  254.             Clearly one requires unambiguous names in the sense that one
  255.           name should refer to only one logical object. This is the case
  256.           with all the addressing schemes in use, whether they are
  257.           directory systems or physical addresses. (The internet
  258.           addresses all rely on the domain name (Mockapetris 1987) of
  259.           the host to achieve this).
  260.             However, given that names can be translated, many apparently
  261.           different names  may lead to the same object. Any object may
  262.           therefore be referred to by many  names. One needs to be able
  263.           to know whether two objects, retrieved through  different
  264.           paths, are in fact the same object.
  265.             It is suggested that each object have a unique                                                    unique                                                    unique "official"
  266.           name. This name could be stored in the object in some
  267.           representations, or stored in a database  accessible to the
  268.           server, for example.  Any references within that object
  269.           should be parsed in the context of the official name.  In the
  270.           presence of a  directory service, the official name will
  271.           normally be the registered name of the object. However, a name
  272.           in any scheme will do, so long as it is completely specified.
  273.           On systems which do not allow the name to be stored (such as
  274.           anonymous FTP archive sites), a possible ambiguity will always
  275.           exist as to whether two similarly named objects are in fact
  276.           the same.
  277.             Note that Internet newsgroup names are unique world-wide,
  278.           and news articles carry a unique message id.
  279.  
  280.  
  281.  
  282. Internet Draft               5              March 1993 Uniform Resource Locators                        Berners-Lee
  283.  
  284.  
  285.             In most other cases, however, there is no guarantee that
  286.           dereferencing a URL will work, or that if it does the object
  287.           it refers to will in fact be the object intended.  URLs such
  288.           as FTP addresses are transient in that files may be moved and
  289.           even replaced by different files of the same name.  This
  290.           disorganisation may be limited by good server management,  but
  291.           a naming scheme which is independent also of internet host
  292.           name is obviously preferable.
  293.  
  294.         Readability by people
  295.  
  296.              This requirement has been put forward by several people
  297.           (Clifford Lynch, Douglas Engelbart among others), and disputed
  298.           by others.  The author's view is that it will be a while
  299.           before technology and standardisation have reached the point
  300.           at which names and addresses will be hidden from human beings.
  301.           As long as they must be written on the backs of envelopes and
  302.           "cut and pasted" between workstation windows, there is a
  303.           strong need for names to be
  304.                   . Short
  305.                   . Composed of printable (preferably non-white)
  306.                     characters
  307.                   . To a certain extent, understadable by a human being.
  308.  
  309.  
  310.         Structure of names and addresses.
  311.  
  312.  
  313.             A physical address is required in order for
  314.  
  315.                   . The user's program to contact the server
  316.                   . The server to search and index,  retrieve a object,
  317.                     or look up the name;
  318.                   . The user's program to locate an individual position
  319.                     or element within a object.
  320.  
  321.             This suggests that a name be structured, such that the parts
  322.           necessary for these  three operations be separate and only
  323.           used by those system elements which need  those parts. This
  324.           corresponds to the basic principle of information hiding.  In
  325.           fact,  four parts are necessary, including the indicator of
  326.           the naming scheme to be used:
  327.  
  328.                   . The naming scheme: a registered identifier for the
  329.                     protocol.
  330.                   . The name of a suitable server. The format of this
  331.                     part must be well defined. It will depend on the
  332.                     lower-layer protocols in use.  Systems which use
  333.                     widely distributed information, such as x.500 and
  334.                     NNTP, do not need this part as each client generally
  335.                     contacts his nearest server (or a particular
  336.                     server).
  337.  
  338.  
  339. Internet Draft               6              March 1993 Uniform Resource Locators                        Berners-Lee
  340.  
  341.  
  342.                   . Information to be passed to the server. This may be
  343.                     private to the server, as all names may be generated
  344.                     and used by the same server. This part of the name
  345.                     should be opaque to the client.
  346.                   . Information to be used by the application once the
  347.                     object has been retrieved.  This part is private to
  348.                     the application (or, more strictly, the data format)
  349.                     and so cannot be defined here.
  350.  
  351.             Both lasting names and physical addresses often share a
  352.           hierarchical structure. This follows often from the
  353.           organisation of the system. From the naming point of view, it
  354.           has the advantage that a reference in one object to another
  355.           object need not include that part of the structure which is
  356.           common to both names.
  357.  
  358.         Choices
  359.  
  360.             The requirements above leave little room for choice save for
  361.           the order and punctuation of the elements of an address.  It
  362.           is only reasonable for the order of writing of the parts to be
  363.           consistently from left to right (or right to left) with
  364.           increasing specificity.  Punctuation schemes fall into two
  365.           categories (Huitema 1991): tagged schemes in which field are
  366.           given names, and fields which use special characters and field
  367.           order. The latter tend to be more compact schemes.
  368.  
  369.  
  370.  
  371.                     protocol: aftp host: xxx.yyy.edu path:
  372.                     /pub/doc/README
  373.  
  374.                     PR=aftp; H=xx.yy.edu; PA=/pub/doc/README;
  375.  
  376.                     PR:aftp/xx.yy.edu/pub/doc/README
  377.  
  378.                     /aftp/xx.yy.edu/pub/doc/README
  379.  
  380.  
  381.  
  382.             Fig 1. Some alternative tagged and untagged representations
  383.  
  384.             The choice of special symbols for punctuation tends to be a
  385.           matter of taste. It is easier to read  addresses whose symbols
  386.           correspond to those of one's favourite operating system.  A
  387.           variety of symbols is needed so that when a name is
  388.           abbreviated it is possible to tell which parts have been
  389.           omitted. The  recommendation below uses special characters in
  390.           order to achieve a compact name, and uses where possible
  391.           punctuation symbols established in the internet or unix
  392.           community.
  393.  
  394.  
  395.  
  396. Internet Draft               7              March 1993 Uniform Resource Locators                        Berners-Lee
  397.  
  398.  
  399.             The choice of escape character for introducing
  400.           representations of non-allowed characters also tends to be a
  401.           matter of taste. An ANSI standard exists in the C language,
  402.           using the back-slash character "\". The use of this character
  403.           on unix command lines, however, can be a problem as it is
  404.           interpreted by many shell programs, and would have itself to
  405.           be escaped.
  406.             The use of white space characters has been avoided  in URLs:
  407.           spaces are not legal characters.   This was done because of
  408.           the frequent introduction of extraneous white space when lines
  409.           are wrapped by systems such as mail, or sheer necessity of
  410.           narrow column width, and because of the  inter-conversion of
  411.           various forms of white space which occurs during character
  412.           code conversion and the transfer of text between applications.
  413.  
  414.  
  415.      Recommendations
  416.  
  417.             This section describes the syntax for "Uniform Resource
  418.           Locators" (URLs):  that is, basically physical addresses of
  419.           objects which are retrievable using protocols already deployed
  420.           on the net.  The generic syntax provides a framework for new
  421.           schemes for names to be resolved using as yet undefined
  422.           protocols.
  423.             The syntax is described in two parts. Firstly, we give the
  424.           syntax rules of a completely specified name;  secondly, we
  425.           give the rules under which parts of the name may be omitted in
  426.           a well-defined context.
  427.  
  428.         Full form
  429.  
  430.             A complete URL consists of a naming scheme specifier
  431.           followed by a string whose format is a function of the naming
  432.           scheme. For locators of information on the internet, a common
  433.           syntax is used for the  IP address part. A BNF description of
  434.           the URL syntax is given in an a later section.  The components
  435.           are as follows.
  436.  
  437.         Fragment-id
  438.  
  439.             This represents a part of, fragment of, or a sub-function
  440.           within, an object or object. Its syntax and semantics are
  441.           defined by the application responsible for the object, or the
  442.           specification of the content type of the object. The only
  443.           definition here is of the allowed characters by which it may
  444.           be represented in a URL.
  445.             The fragment-id follows the URL of the whole object from
  446.           which it is separated by a hash sign (#).  If the fragment-id
  447.           is void, the hash sign may be omitted: A void fragment-id with
  448.           or without the hash sign means that the URL refers to the
  449.           whole object.
  450.  
  451.  
  452.  
  453. Internet Draft               8              March 1993 Uniform Resource Locators                        Berners-Lee
  454.  
  455.  
  456.             While this hook is allowed for identification of fragments,
  457.           the question of addressing of parts of objects, or of the
  458.           grouping of objects and relationship between contined and
  459.           containing objects, is not addressed by this object.
  460.             This object does not address the question of objects which
  461.           are different versions of a "living" object, nor of expressing
  462.           the relationships between different versions and the living
  463.           object.
  464.  
  465.         Scheme
  466.  
  467.  
  468.             Within the URL of a object, the first element is the name of
  469.           the scheme, separated from the rest of the object by a colon.
  470.           The rest of the URL follows the colon in a format depending on
  471.           the scheme.
  472.  
  473.  
  474.         Internet protocol parts
  475.  
  476.  
  477.             Those schemes which refer to internet protocols have a
  478.           common syntax for the rest of the object name. This starts
  479.           with a double slash "//" to indicate its presence, and
  480.           continues until the following slash "/".  Within that section
  481.           are
  482.  
  483.                   . An optional user name, if this must be quoted to the
  484.                     server, followed by  a commercial at sign "@".  (Use
  485.                     of this field is discouraged. Provision  of encoding
  486.                     a password after the user name, delimited by a
  487.                     colon, could  be made but obviously is only useful
  488.                     when the password is public, in  which case it
  489.                     should not be necessary, so that is also
  490.                     discouraged.)
  491.                   . The internet domain name  of the host in RFC1037
  492.                     format (or, optionally  and less advisably, the IP
  493.                     address as a set of four decimal digits)
  494.                   . The port number, if it is not the default number for
  495.                     the protocol, is given in decimal notation after a
  496.                     colon.
  497.  
  498.  
  499.         Path
  500.  
  501.             The rest of the locator is known as the "path". It may
  502.           define details of how the client should communicate with the
  503.           server, including information to be passed transparently to
  504.           the server without any processing by the client.
  505.             The path is interpreted in a manner dependent on the
  506.           protocol being used. However, when it contains slashes, these
  507.           must imply a hierarchical structure.
  508.  
  509.  
  510. Internet Draft               9              March 1993 Uniform Resource Locators                        Berners-Lee
  511.  
  512.  
  513.  
  514.         Partial form
  515.  
  516.             In a certain limited set of cases, generally within a
  517.           certain application, it may be useful to pass only a section
  518.           of the URL. Within a object whose URL is well defined, the URL
  519.           of another object may be given in abbreviated form, where
  520.           parts of the two URLs are the same. This allows objects within
  521.           a group to refer to each other without requiring the space for
  522.           a complete reference, and it incidentally allows the group of
  523.           objects  to be moved without changing any references.  This is
  524.           not discussed in detail here, it is only mentioned so that the
  525.           characters required by the technique be reserved for that
  526.           purpose.  It must be emphasised that when a reference is
  527.           passed in anything other than a well controlled context, the
  528.           full form must always be used.
  529.             The partial form relies on a property of the URL syntax that
  530.           certain characters ("/") and certain path elements ("..", ".")
  531.           have a significance reserved for representing a hierarchical
  532.           space, and must be recognised as such by both clients and
  533.           servers.
  534.             A partial form can be distinguished from a full form in that
  535.           a full form must have a colon and that colon must occur before
  536.           any slash characters.
  537.             The rules for the use of a partial name are:
  538.                   . If the scheme parts  are different, the whole
  539.                     absolute locator must be given. Otherwise, the
  540.                     scheme is omitted, and:
  541.                   . If the host and/or port parts are the different, the
  542.                     host, port name and all the rest of the locator must
  543.                     be given.
  544.                   . If the access and host parts are the same, then the
  545.                     path may be given in absolute (fully qualified) or
  546.                     relative form. Within the path:
  547.                   . If a leading slash is present, the path is absolute.
  548.                     Otherwise, a relative path is interpreted as
  549.                     follows:
  550.                   . The last part of the path of the context locator
  551.                     (anything following the rightmost slash) is removed,
  552.                     and the given partial URL appended in its place.
  553.                   . Within the result,  all occurrences of "/xxx/.."  or
  554.                     "/." are recursively removed, where xxx, ".." and
  555.                     "."  are complete path elements.
  556.  
  557.  
  558.         Encoding prohibited characters
  559.  
  560.             When a system uses a local addressing scheme, it is useful
  561.           to provide a mapping from local addresses into URLs so that
  562.           references to objects within the addressing scheme may be
  563.           referred to globally, and possibly accessed through gateway
  564.           servers.
  565.  
  566.  
  567. Internet Draft               10             March 1993 Uniform Resource Locators                        Berners-Lee
  568.  
  569.  
  570.             Any mapping scheme may be defined provided it is
  571.           unambiguous, reversible, and provides valid URLs. It is
  572.           recommended that where hierarchical aspects to the local
  573.           naming scheme exist, they be mapped onto the hierarchical URL
  574.           path syntax in order to allow the partial form to be used.
  575.             The following encoding method is used for mapping WAIS, FTP,
  576.           Prospero and Gopher addresses onto URLs.  Where the local
  577.           naming scheme uses ASCII characters which are not allowed in
  578.           the URL,  these may be represented in the URL by a percent
  579.           sign "%" followed by two hexadecimal digits (0-9, A-F) giving
  580.           the ISO Latin 1 code for that character.  Character codes
  581.           other than those allowed by the syntax shall not be used in a
  582.           URL.
  583.             The same encoding method may be used for encoding characters
  584.           whose use, although technically allowed in a URL, would be
  585.           unwise due to problems of corruption by imperfect gateways or
  586.           misrepresentation due to the use of variant character sets, or
  587.           which would simply be awkward in a given environment.  As a %
  588.           sign always indicates an encoded character, a URL may be made
  589.           safer simply by encoding any characters considered unsafe,
  590.           while leaving already encoded characters still encoded.
  591.             (Note: If a new naming scheme is introduced which encodes
  592.           binary data as opposed to text, then a more compact encoding
  593.           such as pure hex or base 64 would be more appropriate.)
  594.             The same considerations apply to mapping local fragment
  595.           identifiers onto the fragmentid part of a URL.
  596.  
  597.      Specific Naming Schemes
  598.  
  599.             The mapping for some existing standard and experimental
  600.           protocols is outlined in the BNF syntax definition.  Notes on
  601.           particular protocols follow.
  602.  
  603.         HTTP
  604.  
  605.             The HTTP protocol specifies that the path is handled
  606.           transparently by those who handle URLs, except for the servers
  607.           which dereference them.   The path is passed by the client to
  608.           the server with any request, but is not otherwise understood
  609.           by the client.  The fragmentid part is not sent with the
  610.           request.  The search part, if present, is sent.
  611.  
  612.         FTP
  613.  
  614.             The ftp: prefix indicates a file which is to be picked up
  615.           from the file system of the given host. The FTP protocol is
  616.           used. The port number if given gives the port of the FTP
  617.           server if not the FTP default. (A client may in practice use
  618.           local file access to retrieve objects which are available
  619.           though more efficient means such as local file open or NFS
  620.           mounting, where this is available and equivalent)
  621.  
  622.  
  623.  
  624. Internet Draft               11             March 1993 Uniform Resource Locators                        Berners-Lee
  625.  
  626.  
  627.             The syntax allows for the inclusion of a user name and even
  628.           a password for those systems which do not use the anonymous
  629.           FTP convention. The default, however, if no user or password
  630.           is supplied, will be to use that convention, viz. that the
  631.           user name is "anonymous" and the password the user's mail
  632.           address.
  633.             The adoption of a unix-style syntax involves the conversion
  634.           into non-unix local forms by either the client or server. Some
  635.           non-unix servers do this, but clients wishing to access sites
  636.           which do not have unix-style naming will need certain
  637.           algorithms to enable  other file systems to be identified and
  638.           treated.  Client software may also have to be flexible in
  639.           terms of the sequence of FTP commands used with different
  640.           varieties of server.  In view of a tendency for file systems
  641.           to look increasingly similar, it was felt that the URL
  642.           convention should not be weighed down by extra mechanisms for
  643.           identifying these cases.
  644.             The data format of a file can only, in the general FTP case,
  645.           be deduced from the name, normally the suffix of the name.
  646.           This is not standardised. The transfer mode (binary or text)
  647.           must in turn be deduced from the data format.  It is
  648.           recommended that conventions for suffixes of public archives
  649.           be established, but it outside the scope of this paper.
  650.  
  651.         News
  652.  
  653.             The news locators refer to either news group names or
  654.           article message identifiers which must conform to the rules of
  655.           RFC 850.  A message identifier may be distinguished from a
  656.           news group name by the presence of the commercial at "@"
  657.           character.   These rules imply that within an article, a
  658.           reference to a news group or to another article will be a
  659.           valid URL (in the partial form).
  660.             Note: An outstanding problem is that the message identifier
  661.           is insufficient to allow the retrieval of an expired article,
  662.           as no algorithm exists for deriving an archive site and
  663.           filename.  The addition of the date and news group set to the
  664.           article's URL would allow this if a directory existed of
  665.           archive sites by news group.  Suggested subject of study in
  666.           conjunction with NNTP WG.  Further extension possible may be
  667.           to allow the naming of subject threads as addressable objects.
  668.  
  669.         WAIS
  670.  
  671.             The current WAIS implementation public domain requires that
  672.           a client know the "type" and length of a object prior to
  673.           retrieval.  These values are returned along with the internal
  674.           object identifier in the search response.  They have been
  675.           encoded into the path part of the URL in order to make the URL
  676.           sufficient for the retrieval of the object.  If  changes to
  677.           WAIS specifications make the internal id something which is
  678.  
  679.  
  680.  
  681. Internet Draft               12             March 1993 Uniform Resource Locators                        Berners-Lee
  682.  
  683.  
  684.           sufficient for later retrieval then this will not be
  685.           necessary.
  686.             Within the WAIS world, names do not of course not need to be
  687.           prefixed by "wais:"  (by the partial form rules).
  688.  
  689.         Prospero
  690.  
  691.             The Prospero (Neuman, 1991) directory srvice is used to
  692.           resolve the URL yielding an access method for the object
  693.           (which can then itself be represented as a URL if translated).
  694.           The host part contains a host name or internet address.  The
  695.           port part is optional.  The path part contains a host specific
  696.           object name, an optional version number, and an optional list
  697.           of attributes.  If these latter feilds are present thy are
  698.           separated from the host specific object name and from each
  699.           other by the characters "%00" (percent, zero, zero),  this
  700.           being and escaped string terminator (null).  If the optional
  701.           list of attributes is provided, the version number must be
  702.           present, but may be the empty string (i.e. the first attribute
  703.           would be seperaed from the host specific name by "%00%00").
  704.           External Prospero links are represented directly as URLs of
  705.           the underlying access method and are not represented as
  706.           Prospero URLs.
  707.  
  708.         Gopher
  709.  
  710.             The first character of the URL path part (after the initial
  711.           single slash) is a single-character "type" field which is that
  712.           used by the Gopher protocol.  The rest of the path is the
  713.           "selector string", with disallowed characters encoded. Note
  714.           that some selector strings begin with a copy of the gopher
  715.           type character, in which case that character will occur twice
  716.           consecutively in the URL.  If the type character and selector
  717.           are omitted, the type defaults to "1".
  718.             Gopher links which refer to different protocols should be
  719.           converted into URLs for those protocols.
  720.  
  721.         Telnet, rlogin, tn3270
  722.  
  723.             The use of URLs to represent interactive sessions is a
  724.           convenient extension to their uses for objects.  This allows
  725.           access to information systems which only provide an
  726.           interactive service, and no information server.  As
  727.           information within the service cannot be addressed
  728.           individually or, in general, automatically retrieved, this is
  729.           a less desirable, though currently common, solution.
  730.  
  731.         x500
  732.  
  733.             The mapping of x500 names onto URLs is not defined here. A
  734.           decision is required as to whether "distinguished names" or
  735.           "user friendly names" (ufn), or both, should be allowed. If
  736.  
  737.  
  738. Internet Draft               13             March 1993 Uniform Resource Locators                        Berners-Lee
  739.  
  740.  
  741.           any punctuation conversions are needed from the adopted x500
  742.           representation (such as the use of slashes between parts of a
  743.           ufn) they must be defined. This is a subject for study.
  744.  
  745.         WHOIS
  746.  
  747.             This prefix describes the access using the "whois++" scheme
  748.           in the process of definition. The hostname part is the same as
  749.           for other IP based schemes. The path part can be either a
  750.           whois handle for a whosi object, or it can be a valid whois
  751.           query string. This is a subject for further study.
  752.  
  753.         Network Management Database
  754.  
  755.             This is a subject for study.
  756.  
  757.  
  758.         Registration of naming schemes
  759.  
  760.             A new naming scheme may be introduced by defining a mapping
  761.           onto a conforming URL syntax, using a new scheme identifier.
  762.           Experimental scheme identifiers may be used by mutual
  763.           agreement between parties, and must start with the characters
  764.           "x-".  The scheme name "urn:" is reserved for the work in
  765.           progress on a scheme for more persistent names.  Therefore
  766.           URNs (Names) and URLs (Locators)  be distinguishable.  An
  767.           object which is either a URL or a URN is known as a URI
  768.           (Identifier).
  769.             It is proposed that the Internet Assigned Numbers Authority
  770.           (IANA) perform the function of registration of new schemes.
  771.           Any submission of a new URL scheme must include a definition
  772.           of an algorithm for the retrieval of any object within that
  773.           scheme. The algorithm must take  the URL and produce either a
  774.           set of URL(s) which will lead to the desired object, or the
  775.           object itself, in a well-defined or determinable format. It is
  776.           recommended that those proposing a new scheme demonstrate its
  777.           utility and operability by the provision of a gateway which
  778.           will provide images of objects in the new scheme for clients
  779.           using an existing protocol.  If the new scheme is not a
  780.           locator scheme, then the properties of names in the new space
  781.           should be clearly defined.
  782.             It is likewise recommended that, where a protocol allows for
  783.           retrieval by URI, that the client software have provision for
  784.           being configured to use specific gateway locators for indirect
  785.           access through new naming schemes.
  786.  
  787.      BNF syntax
  788.  
  789.             This is a BNF-like description of the Uniform Resource
  790.           Locator syntax. A vertical  line "|"  indicates alternatives,
  791.           and [brackets]  indicate optional parts.  Spaces are
  792.           representated by the word "space".   Single letters stand for
  793.  
  794.  
  795. Internet Draft               14             March 1993 Uniform Resource Locators                        Berners-Lee
  796.  
  797.  
  798.           single letters. All words of more than one letter below are
  799.           entities described somewhere in this description.
  800.  
  801.             fragmentaddress   url [ # fragmentid ]
  802.             url            generic | httpaddress | fileaddress |
  803.                            newsaddress | prosperoaddress | telnetaddress
  804.                            | gopheraddress | waisaddress | afsaddress
  805.             generic        scheme :  path [ ? search ]
  806.             scheme         ialpha
  807.             httpaddress    h t t p :   / / hostport  [  / path ] [ ?
  808.                            search ]
  809.             fileaddress    f t p : / / host / path
  810.             afsaddress     a f s : / / cellname / path
  811.             newsaddress    n e w s : groupart
  812.             waisaddress    waisindex | waisdoc
  813.             waisindex      w a i s : / / hostport / database [ ? search
  814.                            ]
  815.             waisdoc        w a i s : / / hostport / database / wtype /
  816.                            digits / path
  817.             groupart       * | group | article
  818.             group          ialpha [ . group ]
  819.             article        xalphas @ host
  820.             database       xalphas
  821.             wtype          xalphas
  822.             prosperoaddress   prosperolink
  823.             prosperolink   p r o s p e r o : / / hostport / hsoname [ %
  824.                            0 0 version [ attributes ] ]
  825.             hsoname        path
  826.             version        digits
  827.             attributes     attribute [ attributes ]
  828.             attribute      alphanums
  829.             telnetaddress  t e l n e t : / / [ user @ ] hostport
  830.             gopheraddress  g o p h e r : / / hostport  [/ gtype  [
  831.                            selector ] ] [ ? search ]
  832.             hostport        host [ : port ]
  833.             host           hostname | hostnumber
  834.             cellname       hostname
  835.             hostname       ialpha [  .  hostname ]
  836.             hostnumber     digits . digits . digits . digits
  837.             port           digits
  838.             selector       path
  839.             path           void |  xpalphas  [  / path ]
  840.             search         xalphas [ + search ]
  841.             user           xalphas
  842.             fragmentid     xalphas
  843.             gtype          xalpha
  844.             xalpha         alpha | digit | safe | extra | escape
  845.             xalphas        xalpha [ xalphas ]
  846.             xpalpha        xalpha | +
  847.             xpalphas       xpalpha [ xpalpha ]
  848.             ialpha         alpha [ xalphas ]
  849.  
  850.  
  851.  
  852. Internet Draft               15             March 1993 Uniform Resource Locators                        Berners-Lee
  853.  
  854.  
  855.             alpha          a | b | c | d | e | f | g | h | i | j | k | l
  856.                            | m | n | o  | p | q | r | s | t | u | v | w
  857.                            | x | y | z | A | B | C  | D | E | F | G | H
  858.                            | I | J | K | L | M | N  | O | P |  Q | R | S
  859.                            | T | U | V | W | X | Y | Z
  860.             digit          0 |1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9
  861.             safe           $ | - | _ | @ | . | &
  862.             extra          ! | * | " |  ' | ( | ) | : | ; | , | space
  863.             escape         % hex hex
  864.             hex            digit | a | b | c | d | e | f | A | B | C | D
  865.                            | E | F
  866.             variant        { | } | |                                   |                                   | | [ | ] | \ | ^ | ~
  867.             punctuation    < | >
  868.             digits         digit [ digits ]
  869.             alphanum       alpha | digit
  870.             alphanums      alphanum [ alphanums ]
  871.             void
  872.  
  873.  
  874.      Security considerations
  875.  
  876.             The URL scheme does not in itself pose a security threat.
  877.           Users should beware that there is no general guarantee that a
  878.           URL which at one time points to a given object continues to do
  879.           so, and does not even at some later time point to a different
  880.           object due to the movement of objects on servers.
  881.  
  882.      Conclusion
  883.  
  884.             A need has been demonstrated, and a number of requirements
  885.           have been stated for uniform resource locators (URLs). A
  886.           scheme has been proposed which builds on existing conventions
  887.           to define a syntax for URLs.  This scheme has been in serious
  888.           use by World-Wide Web (W3) initiative since 1991.  Adoption of
  889.           the scheme in correspondence, standards and software will ease
  890.           the use of references to on-line information in a flexible way
  891.           as the coming information age arrives.
  892.  
  893.      Acknowledgements
  894.  
  895.             This paper builds on the basic W3 design and much discussion
  896.           of these issues by many people on the network.  The discussion
  897.           was particularly stimulated by articles by Clifford Lynch
  898.           (1991), Brewster Kahle (1991) and Wengyik Yeong (1991b).
  899.           Contributions from John Curran (NEARnet), Clifford Neuman
  900.           (ISI) Ed Vielmetti (MSEN) and later the IETF URL BOF and URI
  901.           working group have been incorporated into this issue of this
  902.           paper.
  903.             The draft url4  (Innternet draft 00) was generated from url3
  904.           following discussion and overall approval of the URL working
  905.           group on 29 March 1993. The paper url3 had been generated from
  906.           udi2 in the light of discussion at the UDI BOF meeting at the
  907.  
  908.  
  909. Internet Draft               16             March 1993 Uniform Resource Locators                        Berners-Lee
  910.  
  911.  
  912.           Boston IETF in July 1992. Draft url4 was Internet Draft 00.
  913.           Draft url5 incorporated changes suggested by Clifford Neuman,
  914.           and draft url6 (ID 01) incorporated character group changes
  915.           and a few other fixes defined by the IETF URI WG in submitting
  916.           it as a proposed standard.
  917.  
  918.      References
  919.  
  920.         Alberti, R., et.al.  (1991) "Notes on the Internet Gopher
  921.             Protocol" University of Minnesota, December 1991,
  922.             URL=<ftp://boombox.micro.umn.edu/pub/gopher/gopher_protocol
  923.             >. See also
  924.             URL=<gopher://gopher.micro.umn.edu/00/Information%20About%2
  925.             0Gopher/About%20Gopher>
  926.         Berners-Lee, T., (1991) "Hypertext Transfer Protocol (HTTP)",
  927.             CERN, December 1991,
  928.             URL=<ftp://info.cern.ch./pub/www/doc/http-spec.txt>
  929.         Davis, F, et  al., (1990) "WAIS Interface Protocol: Prototype
  930.             Functional Specification", Thinking Machines Corporation,
  931.             April 23, 1990
  932.             URL=<ftp://quake.think.com/pub/wais/doc/protspec.txt>
  933.         International Standards Organization, (1991) Information and
  934.             Documentation - Search and Retrieve Application Protocol
  935.             Specification for open Systems Interconnection, ISO-10163
  936.         Huitema, C., (1991) "Naming: strategies and techniques",
  937.             Computer Networks and ISDN Systems 23 (1991) 107-110.
  938.         Kahle, Brewster, (1991) "Document Identifiers,  or
  939.             International Standard Book Numbers for the Electronic
  940.             Age", URL=<ftp://quake.think.com/pub/wais/doc/doc-ids.txt>
  941.         Kantor, B., and Lapsley, P., (1986) "A proposed standard for
  942.             the stream-based transmission of news", Internet RFC-977,
  943.             February 1986. URL=<ftp://nnsc.nsf.net/rfc/rfc977.txt>
  944.         Lynch, C., Coallition for Networked Information: (1991)
  945.             "Workshop on ID and Reference Structures for Networked
  946.             Information", November 1991. See
  947.             URL=<wais://quake.think.com/wais-discussion-archives?lynch>
  948.         Mockapetris, P., (1987) "Domain names + concepts and
  949.             facilities", RFC-1034, USC-ISI, November 1987,
  950.             URL=<ftp://nnsc.nsf.net/rfc/rfc1034.txt>
  951.         Neuman, B. Clifford, (1992) "Prospero: A Tool for Organizing
  952.             Internet Resources", Electronic Networking: Research,
  953.             Applications and Policy, Vol 1 No 2, Meckler Westport CT
  954.             USA.  See also
  955.             URL=<ftp://prospero.isi.edu/pub/prospero/oir.ps>
  956.         Postel, J. and Reynolds, J. (1985)  "File Transfer Protocol
  957.             (FTP)", Internet RFC-959, October 1985.
  958.             URL=<ftp://nnsc.nsf.net/rfc/rfc959.txt>
  959.         Yeong, W., (1991a) "Towards Networked Information Retrieval",
  960.             Technical report 91-06-25-01, June 1991, Performance
  961.             Systems International, Inc.
  962.             URL=<ftp://uu.psi.com/wp/nir.txt>
  963.  
  964.  
  965.  
  966. Internet Draft               17             March 1993 Uniform Resource Locators                        Berners-Lee
  967.  
  968.  
  969.         Yeong, W., (1991b), "Representing Public Archives in the
  970.             Directory", Internet Draft, November 1991.  In
  971.             <wais://nnsc.nsf.net/internet-drafts?yeong>. Work in
  972.             progress.
  973.  
  974.         Author's address
  975.  
  976.  
  977.                Tim Berners-Lee
  978.                World-Wide Web project
  979.                CERN, 1211 Geneva 23, Switzerland
  980.                +41 (22)767 3755
  981.                timbl@info.cern.ch
  982.  
  983.  
  984.  
  985.  
  986.  
  987.  
  988.  
  989.  
  990.  
  991.  
  992.  
  993.  
  994.  
  995.  
  996.  
  997.  
  998.  
  999.  
  1000.  
  1001.  
  1002.  
  1003.  
  1004.  
  1005.  
  1006.  
  1007.  
  1008.  
  1009.  
  1010.  
  1011.  
  1012.  
  1013.  
  1014.  
  1015.  
  1016.  
  1017.  
  1018.  
  1019.  
  1020.  
  1021.  
  1022.  
  1023. Internet Draft               18             March 1993
  1024.